package net.xdclass.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @Classname ProductOrderVo
 * @Description TODO
 * @Date 2022/8/17 17:39
 * @Created by sunhao
 */
@Data
public class ProductOrderVo {


  private Long id;

  /**
   * 订单唯一标识
   */
  @JsonProperty(value = "out_trade_no")
  private String outTradeNo;

  /**
   * NEW 未支付订单,PAY已经支付订单,CANCEL超时取消订单
   */
  private String state;

  /**
   * 订单生成时间
   */
  @JsonProperty(value = "create_time")
  private Date createTime;

  /**
   * 订单总金额
   */
  @JsonProperty(value = "total_amount")
  private BigDecimal totalAmount;

  /**
   * 订单实际支付价格
   */
  @JsonProperty(value = "pay_amount")
  private BigDecimal payAmount;

  /**
   * 支付类型，微信-银行-支付宝
   */
  @JsonProperty(value = "pay_type")
  private String payType;

  /**
   * 昵称
   */
  @JsonProperty(value = "nick_name")
  private String nickname;

  /**
   * 头像
   */
  @JsonProperty(value = "head_img")
  private String headImg;

  /**
   * 更新时间
   */
  @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",locale = "zh",timezone = "GMT+8")
  @JsonProperty(value = "update_time")
  private Date updateTime;

  /**
   * 订单类型 DAILY普通单，PROMOTION促销订单
   */
  @JsonProperty(value = "order_type")
  private String orderType;

  /**
   * 收货地址 json存储
   */
  @JsonProperty(value = "receiver_address")
  private String receiverAddress;


  /**
   * 订单产品
   */
  @JsonProperty(value = "product_order_items")
  private List<ProductOrderItemVo> productOrderItemVos;
}
